package com.seed.core.pojo;

import com.mybatisflex.core.query.QueryCondition;
import com.mybatisflex.core.query.QueryTable;
import com.seed.core.enumeration.JoinType;

public class Join {
    private QueryTable table;
    private QueryCondition on;
    private JoinType joinType;

    public Join(QueryTable table, QueryCondition on) {
        this.table = table;
        this.on = on;
        this.joinType = JoinType.left;
    }

    public Join(QueryTable table, QueryCondition on, JoinType joinType) {
        this.table = table;
        this.on = on;
        this.joinType = joinType;
    }

    public QueryTable getTable() {
        return table;
    }

    public void setTable(QueryTable table) {
        this.table = table;
    }

    public QueryCondition getOn() {
        return on;
    }

    public void setOn(QueryCondition on) {
        this.on = on;
    }

    public JoinType getJoinType() {
        return joinType;
    }

    public void setJoinType(JoinType joinType) {
        this.joinType = joinType;
    }
}
